
/**
 *
 * @author xerxes
 */
import java.io.*;
import java.lang.*;
import java.math.*;
import java.text.*;
import java.util.*;

public class Main {

    BufferedReader reader;
    BigInteger[] result;
    BigInteger[] remember;

    public static void main(String[] args) throws IOException {
        Main ob = new Main();
        ob.run();
        System.exit(0);
    }

    public void run() throws IOException {
        generate();
        reader = new BufferedReader(new InputStreamReader(System.in));
        String line = "";
        while ((line = reader.readLine()) != null) {
            int n = nextInt(line);
            System.out.println(result[n]);
        }

    }

    public void generate() {
        result = new BigInteger[1010];
        remember = new BigInteger[1010];

        Arrays.fill(result, BigInteger.ZERO);
        Arrays.fill(remember, BigInteger.ZERO);

        result[2] = remember[2] = BigInteger.ONE;
        for (int i = 3; i <= 1000; ++i) {
            result[i] = result[i - 1].add(remember[i - 2]);

            if (i % 2 == 0) { // if even need extra one to add
                result[i] = result[i].add(BigInteger.ONE);
            }
            remember[i] = remember[i - 1].add(result[i]);
            //System.out.println( i+" "+ result[i] );
        }
    }

    public int nextInt(String str) {
        return Integer.parseInt(str);
    }
}